/************************************************
 * Author       :   XXY
 * Blog         :   https://www.cnblogs.com/jzyl
 * Gitee        :   https://gitee.com/xiaobaichong
 * Email        :   1047185209@QQ.com
 * FileName     :   OnlineToolbox.cs
 * CreateData   :   2023/10/30 8:02:43
 * UnityVersion :   2021.3.30f1c1
 * Description  :   在线工具箱
************************************************/

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using Sirenix.OdinInspector;
using System.Runtime.CompilerServices;

public class OnlineToolbox
{
    [Title("Head")]
    [LabelWidth(150), Multiline]
    public string _Description = "在线工具箱";

    #region Unity 官网
    [BoxGroup("Unity 官网"), Button]
    private void OpenUnityManual()
    {
        OpenWebByURL("https://docs.unity.cn/cn/current/Manual/index.html");
    }
    [BoxGroup("Unity 官网"), Button]
    private void OpenUnityScriptReference()
    {
        OpenWebByURL("https://docs.unity.cn/cn/current/ScriptReference/index.html");
    }
    [BoxGroup("Unity 官网"), Button]
    private void OpenUnityStore()
    {
        OpenWebByURL("https://assetstore.unity.com/zh");
    }
    [BoxGroup("Unity 官网"), Button]
    private void OpenUnityGitHub()
    {
        OpenWebByURL("https://github.com/Unity-Technologies");
    }
    #endregion
    #region 热更
    [BoxGroup("热更"), Button]
    private void OpenPuerTS()
    {
        OpenWebByURL("https://puerts.github.io/");
    }
    [BoxGroup("热更"), Button]
    private void OpenXLua()
    {
        OpenWebByURL("https://github.com/Tencent/xLua");
    }
    [BoxGroup("热更"), Button]
    private void OpenILRuntime()
    {
        OpenWebByURL("https://ourpalm.github.io/ILRuntime/public/v1/guide/index.html");
    }
    [BoxGroup("热更"), Button]
    private void OpenHybridCLR()
    {
        OpenWebByURL("https://hybridclr.doc.code-philosophy.com/");
    }
    #endregion
    #region 序列化
    [BoxGroup("序列化"), Button]
    private void OpenXML()
    {
        OpenWebByURL("https://learn.microsoft.com/zh-cn/dotnet/api/system.xml.xmldocument");
    }
    [BoxGroup("序列化"), Button]
    private void OpenNewtonsoftJson()
    {
        OpenWebByURL("https://www.newtonsoft.com/json/help/html/Introduction.htm");
    }
    [BoxGroup("序列化"), Button]
    private void OpenGoogleProtocolBuffers()
    {
        OpenWebByURL("https://protobuf.dev/");
    }
    [BoxGroup("序列化"), Button]
    private void OpenExcel()
    {
        OpenWebByURL("");
    }
    #endregion
    #region ChatGPT
    [BoxGroup("ChatGPT"), Button]
    private void OpenAI_1()
    {
        OpenWebByURL("https://www.zxf7460.cn/chat");
    }
    [BoxGroup("ChatGPT"), Button]
    private void OpenAI_2()
    {
        OpenWebByURL("https://lab.aiwht.com/chat");
    }
    #endregion
    #region 其他工具
    [BoxGroup("其他工具"), Button]
    private void OpenRegex()
    {
        OpenWebByURL("https://www.mklab.cn/utils/regex");
    }
    #endregion
    private void OpenWebByURL(string url)
    {
        Application.OpenURL(url);
    }
}
